package com.zj.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.springframework.validation.annotation.Validated;

import javax.validation.constraints.Max;

@Data /*lombok注解  不包含 有参 和 无参 构造方法*/
@Validated  /*启用校验功能*/
public class User {
    @TableId(value = "userid",type = IdType.AUTO)
    private Integer userid;
    private String username;
    @Max(value = 100,message = "最大值不能超400")
    private Float balance;
}
